package com.guigu.userservice.dto;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

@Data
public class Equipment implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "equipment_id", type = IdType.AUTO)
    private Long equipmentId;
    private Long userId;
    private Integer typeId;
    private String brand;
    private String model;
    private Integer year;
    private Integer hour;
    private BigDecimal price;
    private BigDecimal verticalHeight;
    private Integer chassisAxle;
    private String outriggerType;
    private String emissionStandard;
    private String location;
    private String contactName;
    private String contactPhone;
    private String description;
    private Integer status;
    private Integer isDetected;
    private Long detectionReportId;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime releaseTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime auditTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    //映射设备图片
    @TableField(exist = false)
    private  String imageUrl;
    @TableField(exist = false)
    private EquipmentType equipmentType;

    @TableField(exist = false)
    private List<EquipmentImage> equipmentImages;

    @TableField(exist = false)
    private List<EquipmentVideo> equipmentVideos;
}